package cn.HK.service;

import cn.HK.mapper.CheckMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

@Service
public class CheckService {
    @Autowired(required = false)
    private CheckMapper checkMapper;

    /*
    从数据库查询用户名是否存在
     */
    public Boolean checkUsername(String empName) {
       int exist=checkMapper.selectCountByUsername(empName);
       return exist==0;
    }
}
